<?php if (is_plugin_enabled("tidypics")) { ?>
<div id="river_container2">
<div class="dash_pad">
<?php

	//the number of files to display
	$imagesToDisplay = get_plugin_setting("imagesToDisplay", "riverdashboard");
	$number = (int) $vars['entity']->num_display;
	//if no number has been set, default to 6
	if (!$number)
		$number = $imagesToDisplay;
    echo '<h3>' .elgg_echo("river:photo:latest"). '</h3>';
	echo '<div class="tidypics_widget_latest">';
	echo tp_get_latest_photos($number, page_owner());
	echo '</div>';
	
?>
</div>
</div>
<?php } ?>